﻿using DataCenter.IDataProvider;

namespace DataCenter.SystemProvider
{
    public class SystemCodeProvider : ICodeProvider
    {
        public async Task<string> GetLasterCodeAsync(string customerId, string productId)
        {
            return await Task.FromResult($"{customerId}:{productId}:laster 123");
        }

        public async Task<string> GetQRCodeAsync(string customerId, string productId)
        {
            return await Task.FromResult($"{customerId}:{productId}:Qr 1234");
        }
    }

    [UnInstance("这个不应该被注入")]
    public class MySystemCodeProvider : ICodeProvider
    {
        public async Task<string> GetLasterCodeAsync(string customerId, string productId)
        {
            return await Task.FromResult($"{customerId}:{productId}:laster nonono");
        }

        public async Task<string> GetQRCodeAsync(string customerId, string productId)
        {
            return await Task.FromResult($"{customerId}:{productId}:Qr nonono");
        }
    }
}
